import type { RouteRecordRaw } from 'vue-router';

import Layout from '@/layouts/index.vue';

export const iframeRoutes: RouteRecordRaw[] = [
  {
    path: '/iframe',
    component: Layout,
    redirect: '/iframe/bilibili',
    meta: {
      title: '外部页面',
      icon: 'InvestmentSetting',
      authCodes: [],
      visible: true,
    },
    children: [
      {
        path: '/iframe/bilibili',
        component: () => import('@/layouts/iframe/index.vue'),
        meta: {
          authCodes: [],
          title: '哔哩哔哩(内嵌)',
          iframeSrc: 'https://www.bilibili.com/',
          isPageReused: true,
        },
      },
      {
        path: '/iframe/usage',
        component: () => import('@/layouts/iframe/index.vue'),
        meta: {
          authCodes: [],
          title: 'Template Usage(内嵌)',
          iframeSrc: 'https://dony.online/usage/',
          isPageReused: true,
        },
      }
    ],
  }
];
